package com.aidex.tina.domain;

import java.math.BigDecimal;
import java.util.List;
import lombok.Data;
import com.aidex.common.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.aidex.common.utils.log.annotation.FieldRemark;
import com.aidex.common.utils.log.annotation.LogField;
import com.aidex.common.annotation.Excel;

/**
 * 采购订单对象 tina_bill
 * @author Stanfine
 * @email shanliang@outlook.com
 * @date 2022-06-08
 */
@Data
public class Bill extends BaseEntity<Bill>
{
    private static final long serialVersionUID = 1L;

    /** 供应商编号 */
    @Excel(name = "供应商编号", dictType = "tina_material_category")
    @LogField
    @FieldRemark(name = "供应商编号",field = "supplierId")
    private String supplierId;

    /** 件数 */
    @Excel(name = "件数")
    private Long count;

    /** 总价 */
    @Excel(name = "总价")
    private BigDecimal totalPrice;

    /** 运费 */
    @Excel(name = "运费")
    @LogField
    @FieldRemark(name = "运费",field = "shipPrice")
    private BigDecimal shipPrice;

    /** 优惠价格 */
    @Excel(name = "优惠价格")
    @LogField
    @FieldRemark(name = "优惠价格",field = "discountPrice")
    private BigDecimal discountPrice;

    /** 最终价格 */
    @Excel(name = "最终价格")
    private BigDecimal realPrice;

    // 采购单状态 0 报价   10 取消   20 确认
    private String status;

    private Supplier supplier;

    private List<BillItem> billItems;

    public void setSupplierId(String supplierId) 
    {
        this.supplierId = supplierId;
    }

    public String getSupplierId() 
    {
        return supplierId;
    }

    public void setCount(Long count) 
    {
        this.count = count;
    }

    public Long getCount() 
    {
        return count;
    }

    public void setTotalPrice(BigDecimal totalPrice) 
    {
        this.totalPrice = totalPrice;
    }

    public BigDecimal getTotalPrice() 
    {
        return totalPrice;
    }

    public void setShipPrice(BigDecimal shipPrice) 
    {
        this.shipPrice = shipPrice;
    }

    public BigDecimal getShipPrice() 
    {
        return shipPrice;
    }

    public void setDiscountPrice(BigDecimal discountPrice) 
    {
        this.discountPrice = discountPrice;
    }

    public BigDecimal getDiscountPrice() 
    {
        return discountPrice;
    }

    public void setRealPrice(BigDecimal realPrice) 
    {
        this.realPrice = realPrice;
    }

    public BigDecimal getRealPrice() 
    {
        return realPrice;
    }


    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("supplierId", getSupplierId())
            .append("count", getCount())
            .append("totalPrice", getTotalPrice())
            .append("shipPrice", getShipPrice())
            .append("discountPrice", getDiscountPrice())
            .append("realPrice", getRealPrice())
            .append("remark", getRemark())
            .append("id", getId())
            .append("createBy", getCreateBy())
            .append("createDept", getCreateDept())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .append("updateIp", getUpdateIp())
            .append("version", getVersion())
            .append("delFlag", getDelFlag())
            .toString();
    }
}
